package com.ag.bean;

import java.util.HashSet;
import java.util.Set;
import javax.persistence.CascadeType;
import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.FetchType;
import javax.persistence.Id;
import javax.persistence.OneToMany;
import javax.persistence.Table;

/**
 * TbPhoneRecord entity.
 * 
 * @author MyEclipse Persistence Tools
 */
@Entity
@Table(name = "TB_PHONE_RECORD", schema = "dbo", catalog = "AGDB")
public class TbPhoneRecord implements java.io.Serializable {

	// Fields

	private String prId;
	private String prPath;
	private String a;
	private String b;
	private String c;
	private Set<TbEvent> tbEvents = new HashSet<TbEvent>(0);

	// Constructors

	/** default constructor */
	public TbPhoneRecord() {
	}

	/** minimal constructor */
	public TbPhoneRecord(String prId, String prPath) {
		this.prId = prId;
		this.prPath = prPath;
	}

	/** full constructor */
	public TbPhoneRecord(String prId, String prPath, String a, String b,
			String c, Set<TbEvent> tbEvents) {
		this.prId = prId;
		this.prPath = prPath;
		this.a = a;
		this.b = b;
		this.c = c;
		this.tbEvents = tbEvents;
	}

	// Property accessors
	@Id
	@Column(name = "PR_ID", unique = true, nullable = false, length = 10)
	public String getPrId() {
		return this.prId;
	}

	public void setPrId(String prId) {
		this.prId = prId;
	}

	@Column(name = "PR_PATH", nullable = false, length = 256)
	public String getPrPath() {
		return this.prPath;
	}

	public void setPrPath(String prPath) {
		this.prPath = prPath;
	}

	@Column(name = "A", length = 60)
	public String getA() {
		return this.a;
	}

	public void setA(String a) {
		this.a = a;
	}

	@Column(name = "B", length = 60)
	public String getB() {
		return this.b;
	}

	public void setB(String b) {
		this.b = b;
	}

	@Column(name = "C", length = 60)
	public String getC() {
		return this.c;
	}

	public void setC(String c) {
		this.c = c;
	}

	@OneToMany(cascade = CascadeType.ALL, fetch = FetchType.LAZY, mappedBy = "tbPhoneRecord")
	public Set<TbEvent> getTbEvents() {
		return this.tbEvents;
	}

	public void setTbEvents(Set<TbEvent> tbEvents) {
		this.tbEvents = tbEvents;
	}

}